package com.example.streamer.util;

import java.awt.*;

public class InputInjector {
    private static final Robot ROBOT;
    static {
        try {
            ROBOT = new Robot();
        } catch (AWTException e) {
            throw new RuntimeException(e);
        }
    }

    public static void moveMouse(int x, int y) {
        ROBOT.mouseMove(x, y);
    }

    public static void mousePress(int button) {
        ROBOT.mousePress(button);
    }

    public static void mouseRelease(int button) {
        ROBOT.mouseRelease(button);
    }

    public static void mouseWheel(int amount) {
        ROBOT.mouseWheel(amount);
    }

    public static void keyPress(int keyCode) {
        ROBOT.keyPress(keyCode);
    }

    public static void keyRelease(int keyCode) {
        ROBOT.keyRelease(keyCode);
    }
} 